home *** CD-ROM | disk | FTP | other *** search
/ Experimental BBS Explossion 3 / Experimental BBS Explossion III.iso / games / nhak_src.zip / VMSCONF.H < prev    next >
C/C++ Source or Header  |  1993-03-16  |  4KB  |  137 lines

  1. /*    SCCS Id: @(#)vmsconf.h    3.0    88/07/21
  2. /* Copyright (c) Stichting Mathematisch Centrum, Amsterdam, 1985. */
  3. /* NetHack may be freely redistributed.  See license for details. */
  4.  
  5. #ifdef VMS
  6. #ifndef VMSCONF_H
  7. #define VMSCONF_H
  8.  
  9. /*
  10.  * Edit these to choose values appropriate for your site.
  11.  * WIZARD is the username allowed to use the debug option of nethack; no harm
  12.  *   is done by leaving it as a username that doesn't exist at your site.
  13.  * HACKDIR can be overridden at run-time with the logical name HACKDIR, as in
  14.  *   $ define hackdir disk$users:[games.nethack]
  15.  */
  16. #define Local_WIZARD    "GENTZEL"               /*(must be uppercase)*/
  17. #define Local_HACKDIR   "USR$ROOT0:[GENTZEL.NHDIR]"
  18.  
  19. /*
  20.  * This section cleans up the stuff done in config.h so that it
  21.  * shouldn't need to be modified.  It's conservative so that if
  22.  * config.h is actually edited, the changes won't impact us.
  23.  */
  24. #ifdef UNIX
  25. # undef UNIX
  26. #endif
  27. #ifdef HACKDIR
  28. # undef HACKDIR
  29. #endif
  30. #ifdef WIZARD
  31. # undef WIZARD
  32. #endif
  33. #ifdef WIZARD_NAME
  34. # undef WIZARD_NAME
  35. #endif
  36. #define HACKDIR Local_HACKDIR
  37. #ifndef KR1ED
  38. # define WIZARD Local_WIZARD
  39. # define WIZARD_NAME WIZARD
  40. #else
  41. # define WIZARD 1
  42. # define WIZARD_NAME Local_WIZARD
  43. #endif
  44.  
  45. #undef RECORD
  46. #define RECORD "record;1"
  47.  
  48. #ifdef COMPRESS
  49. # undef COMPRESS
  50. #endif
  51. #ifdef ZEROCOMP
  52. # undef ZEROCOMP
  53. #endif
  54.  
  55. /*
  56.  * If you define MAIL, then the player will be notified of new broadcasts
  57.  * when they arrive.
  58.  */
  59. #define    MAIL
  60.  
  61. #define RANDOM          /* use others/random.c instead of vaxcrtl rand/srand */
  62.  
  63. #define    FCMASK    0660    /* file creation mask */
  64.  
  65. /* vaxcrtl object library is not available on MicroVMS (4.4 thru 4.6(.7?))
  66.    unless it's retreived from a full VMS system or leftover from a really
  67.    ancient version of VAXC.  #define no_c$$translate and also create a
  68.    linker options file called vaxcrtl.opt containing one line
  69. sys$share:vaxcrtl/shareable
  70.    to link against the vaxcrtl shareable image.  Then include ',vaxcrtl/opt'
  71.    on the link command instead of either ',sys$library:vaxcrtl/lib' or
  72.    '$ define lnk$library sys$library:vaxcrtl'
  73.    Linking against the vaxcrtl sharable image is encouraged and will result
  74.    in significantly smaller .EXE files.  The routine C$$TRANSLATE (used in
  75.    vmsunix.c) is not available from the sharable image version of vaxcrtl.
  76.  */
  77. /* #define no_c$$translate /**/
  78.  
  79. /*
  80.  * The remainder of the file should not need to be changed.
  81.  */
  82.  
  83. /* GCC 1.36 (or maybe GAS) for VMS has a bug with extern const declarations.
  84.    Until it is fixed, eliminate const. */
  85. #ifdef __GNUC__
  86. # define const
  87. #endif
  88. #if defined(VAXC) && !defined(ANCIENT_VAXC)
  89. # ifdef volatile
  90. #  undef volatile
  91. # endif
  92. # ifdef const
  93. #  undef const
  94. # endif
  95. #endif
  96.  
  97. #include <time.h>
  98. #include <file.h>
  99.  
  100. #define    HLOCK    "perm;1"    /* an empty file used for locking purposes */
  101. #define LLOCK    "safelock;1"    /* link to previous */
  102.  
  103. #ifndef REDO
  104. # define Getchar vms_getchar
  105. #else
  106. # define tgetch vms_getchar
  107. #endif
  108.  
  109. #define SHELL        /* do not delete the '!' command */
  110.  
  111. #include "system.h"
  112.  
  113. #define index    strchr
  114. #define rindex    strrchr
  115.  
  116. /* Use the high quality random number routines. */
  117. #if defined(RANDOM)
  118. #define Rand()    random()
  119. #define Srand(seed) srandom(seed)
  120. #else
  121. #define Rand()    rand()
  122. #define Srand(seed) srand(seed)
  123. #endif
  124.  
  125. #define bcopy(s1,s2,sz) memcpy(s2,s1,sz)
  126. #define unlink(x) delete(x)
  127. #define exit(x) vms_exit(x)
  128. #define getuid() vms_getuid()
  129. #define abort() vms_abort()
  130. #define creat(f,m) vms_creat(f,m)
  131.  
  132. /* VMS global names are case insensitive... */
  133. #define An vms_an
  134.  
  135. #endif
  136. #endif /* VMS /* */
  137.